package com.repair.limiter.configuration;

import com.repair.limiter.utils.SmsRateLimiter;
import org.redisson.api.RedissonClient;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author chunyu
 * @since 2024/9/18,20:36
 */
@Configuration
public class RateLimiterConfiguration {

    @Bean
    public SmsRateLimiter smsRateLimiter(RedissonClient redissonClient){
        return new SmsRateLimiter(redissonClient);
    }

}
